package ysq.xyg.shop.service;


import ysq.xyg.base.model.dto.ReturnEntity;
import ysq.xyg.base.service.BaseService;
import ysq.xyg.shop.model.po.ShopOrderCoupon;
import ysq.xyg.shop.model.vo.ShopOrderCouponCountVO;
import ysq.xyg.shop.model.vo.ShopOrderCouponExportVo;
import ysq.xyg.sys.model.po.SysUser;
import ysq.xyg.shop.model.vo.ShopOrderCouponVo;

import java.util.List;

/**
 * 商城模块-商品劵管理service接口
 *
 * @author congcong tao
 * @date 2019-4-28 11:19:33
 */
public interface ShopOrderCouponService extends BaseService<ShopOrderCoupon> {
    /**
     * 分页查询
     *
     * @param shopOrderCouponVo 对象
     * @param pageSize 当前页面
     * @param pageNum 页面数量
     * @return ReturnEntity 对象
     * @author congcong tao
     * @date 2019-4-28 11:19:33
     */
    ReturnEntity page(ShopOrderCouponVo shopOrderCouponVo, int pageSize, int pageNum);

    ReturnEntity pageLeft(ShopOrderCouponVo shopOrderCouponVo, int pageSize, int pageNum);

    ReturnEntity pageRight(ShopOrderCouponVo shopOrderCouponVo, int pageSize, int pageNum);

    /**
     * 修改
     *
     * @param shopOrderCouponVo 对象
     * @param currentUser 当前用户
     * @return ReturnEntity 对象
     * @author congcong tao
     * @date 2019-4-28 11:19:33
     */
    ReturnEntity addOrUpdate(ShopOrderCouponVo shopOrderCouponVo, SysUser currentUser);
    /**
     * 删除
     *
     * @param id 主键id删除
     * @param currentUser 当前用户
     * @return ReturnEntity 对象
     * @author congcong tao
     * @date 2019-4-28 11:19:33
     */
    ReturnEntity delete(String id, SysUser currentUser);
    /**
     * 获取集合
     *
     * @param shopOrderCouponVo 对象
     * @return List<ShopOrderCoupon> ShopOrderCoupon集合
     * @author congcong tao
     * @date 2019-4-28 11:19:33
     */
    List<ShopOrderCoupon> acceptList(ShopOrderCouponVo shopOrderCouponVo);

    /**
     * 查询总价格
     * @param shopOrderCoupon
     * @author congcong tao
     * @date 2019/5/31 13:56
     */
    Double selectSumPrice(ShopOrderCoupon shopOrderCoupon);

    /**
     * 打款，生成order订单，并将原orderCoupon修改字段
     * @param ids 用逗号隔开的ordercoupon
     * @author congcong tao
     * @date 2019/5/31 13:55
     */
    ReturnEntity createOrder(String ids, String description, SysUser sysUser);

    /**
     * 查询统计数据
     * @author congcong tao
     * @date 2019/5/31 17:10
     */
    List<ShopOrderCouponCountVO> selectCountList(String memberId);

    /**
     * 根据订单用户查询
     * @param shopOrderCouponVo
     * @author congcong tao
     * @date 2019-06-10 20:49
     */
    List<ShopOrderCouponExportVo> selectGroupByMember(ShopOrderCouponVo shopOrderCouponVo);

    ReturnEntity pageShowOrder(ShopOrderCouponVo shopOrderCouponVo, int pageSize, int pageNum);

    /**
     * 入库
     */
    ReturnEntity stockIn(String ids);

    /**
     * 全部入库
     * @author congcong tao
     * @date 2019/7/2 10:00
     */
    ReturnEntity allStockIn();

    /**
     * 付现
     */
    ReturnEntity updateCashStatus(String orderId, String memberIds, String cashStatus, String cashMessage);

    /**
     * 根据条件查询
     * @param shopOrderCouponVo
     * @author congcong tao
     * @date 2019-06-16 20:46
     */
    List<ShopOrderCoupon> selectEntityList(ShopOrderCouponVo shopOrderCouponVo);

    /**
     * 根据状态修改
     * @param id
     * @param status
     * @author congcong tao
     * @date 2019/6/17 9:14
     */
    ReturnEntity updateStatusById(String id, String status);

    /**
     * 根据状态修改
     * @param ids
     * @param status
     * @author congcong tao
     * @date 2019/6/20 14:08
     */
    ReturnEntity updateStatusByIds(String ids, String status);

    /**
     * 处理纠纷
     * 纠纷有效，扣除金额
     * @param id
     * @param issueStatus
     * @param issueMessage
     * @param issueResultMessage
     * @author congcong tao
     * @date 2019/6/17 9:15
     */
    ReturnEntity updateIssueStatusById(String id, String issueStatus, String issueMessage, String issueResultMessage);
}
